Correct allocation in xml_tag pseudo copy constructor.
authorrobertlipe <robertlipe@f51c46e8-681c-474f-0cfe-069cfd0219fb>
Fri, 6 Sep 2013 19:27:03 +0000 (19:27 +0000)
committerrobertlipe <robertlipe@f51c46e8-681c-474f-0cfe-069cfd0219fb>
Fri, 6 Sep 2013 19:27:03 +0000 (19:27 +0000)
git-svn-id: http://gpsbabel.googlecode.com/svn/trunk@4591 f51c46e8-681c-474f-0cfe-069cfd0219fb

gpsbabel/xmltag.cc

index 810710b60b795f315e644b843d3e1dae23053290..5e11276d103e07d7414daccaf5e94f3eb2a33b44 100644 (file)
@@ -74,7 +74,7 @@ copy_xml_tag(xml_tag** copy, xml_tag* src, xml_tag* parent)
     return;
   }
 
-  res = (xml_tag*) xcalloc(1, sizeof(xml_tag));
+  res = new xml_tag;
   *copy = res;
 
   memcpy(res, src, sizeof(xml_tag));